package com.xnyzc.lhy.order.service.work;

import com.baomidou.mybatisplus.extension.service.IService;
import com.xnyzc.lhy.common.entity.Rv;
import com.xnyzc.lhy.common.penum.EErrorCode;
import com.xnyzc.lhy.common.penum.order.EOrderStatus;
import com.xnyzc.lhy.order.entity.param.cms.PageDto;
import com.xnyzc.lhy.order.entity.param.order.CharteredDetailsParam;
import com.xnyzc.lhy.order.entity.param.order.DisBookingOrderParam;
import com.xnyzc.lhy.order.entity.work.OaDWorkStatistics;
import com.xnyzc.lhy.order.mo.OrderLogMo;

import java.util.Map;
import java.util.List;

/**
 * <p>
 * 司机工作统计表（日统计，实时更新） 服务类
 * </p>
 *
 * @author zhuyubin
 * @since 2019-08-02
 */
public interface IOaDWorkStatisticsService extends IService<OaDWorkStatistics> {

    /**
     * 获取当天的工作统计
     *
     * @param driverId
     * @param tag
     * @return
     */
    OaDWorkStatistics getWork(Long driverId, String tag);

    /**
     * 获取司机信息
     *
     * @param driverId 司机id
     * @param tag      租户
     * @return
     */
    Map<String, Object> getWorkStatistics(Long driverId, String tag, Integer userType);

    List<Map<String, Object>> getHomeMessage(PageDto pageDto);

    Rv throwOrderToHall(String orderNo);

    List<String> getBookingOrder(String cityId, Long officeId);

    Rv robBookingOrder(long driverId, String orderId);

    Rv disBookingOrder(DisBookingOrderParam param);

    Rv suspendOrder(String orderNo);

    Rv throwBookingOrder(DisBookingOrderParam param);

    Rv disBookingOrderToManager(DisBookingOrderParam param);

    Rv startMyBookingOrder(long driverId, String orderNo, EOrderStatus orderStatus);

    // Rv throwMyBookingOrder(String orderNo);

    /**
     * 供应商接受转订单
     * @param orderNo 订单号
     * @return true = success
     **/
    Boolean orderAccept(String orderNo);

    /**
     * 查询订单追踪记录
     * @param orderNo 订单号
     * @return List
     **/
    List<OrderLogMo> orderTracking(String orderNo);

    Rv assignCharterDriver(CharteredDetailsParam charteredDetailsParam);
}
